#ifndef QXGAME_GAMEMANAGER_H
#define QXGAME_GAMEMANAGER_H

#include "Singleton.h"
#include "GameInputEvents.h"

class GameManager : public Singleton<GameManager>, public GameInputEvents {
    friend class Singleton<GameManager>;

public:
    int Run();

private:
    GameManager();
    ~GameManager();
    void Quit() override;
    void InitAssert(bool flag, char *errmsg);
    void OnInput();
    void OnUpdate(double delta);
    void OnRender();
    void Render();
    void RenderWindow();
    void UpdateMapCenter();
    void ShowBeginInterFace();

private:

    bool isQuit;
    SDL_Texture *tex = nullptr;
    SDL_Window *window = nullptr;
};

#endif // QXGAME_GAMEMANAGER_H
